<?php
/**
 * Created by PhpStorm.
 * User: tao
 * Date: 2016/12/1
 * Time: 上午10:24
 */

namespace Admin\Controller;
use Think\Controller;

class DormitoryController extends CommonController {

    public function dormitory(){
            $m = D('dormitory');
            $res = $m->select();
            $this->assign('res',$res);
            $this->display();
       
           
    }
    public function bed(){
    	    $dormitory =I('get.id');
    	    $m = D('dormitory');
    	    $map = array('dormitory'=>$dormitory);
            $res = $m->where($map)->find();
            $this->assign('res',$res);
            $this->display();
    }
    
}